import { markRaw } from 'vue';
import { RouteRecordRaw } from 'vue-router';
import RouterTransition from '@/components/routerTransition.vue';

const routeName = 'queue';

const routes: Array<RouteRecordRaw> = [
    {
        path: '/queue',
        name: routeName,
        redirect: '/queue/issue',
        component: markRaw(RouterTransition),
        meta: {
            title: 'yl.queueTitle',
            icon: 'CreditCardOutlined',
        },
        children: [
            {
                path: 'issue',
                name: `${routeName}-issue`,
                meta: {
                    title: 'yl.issueQueue',
                    icon: 'stack-light',
                },
                component: () => import(/* webpackChunkName: "goods" */ '@/views/queue/issue/index.vue'),
            },
            {
                path: 'queuePageCutting',
                name: `${routeName}-pagecutting`,
                meta: {
                    title: 'yl.queuePageCutting',
                    icon: 'people',
                },
                component: () => import(/* webpackChunkName: "customer" */ '@/views/queue/pagecutting/index.vue'),
            },
            {
                path: 'flashLight',
                name: `${routeName}-flashLight`,
                meta: {
                    title: 'yl.flashLight',
                    icon: 'people',
                },
                component: () => import(/* webpackChunkName: "customer" */ '@/views/queue/flashLight/index.vue'),
            },
        ],
    },
];

export default routes;
